package basisDemo;

import java.util.concurrent.ArrayBlockingQueue;
import java.util.concurrent.BlockingQueue;
import java.util.concurrent.LinkedBlockingQueue;
import java.util.concurrent.locks.ReentrantLock;

public class GenericDemo {
    public static void main(String[] args) {
        new Node<Integer>(2).setData(5);
    }
}

class Node<T> {
    private T data;

    public Node(T data) {
        this.data = data;
    }

    public void setData(T data) {
        System.out.println(data.getClass());
        this.data = data;
    }
}
